

import discount.DisCountFactory;
import discount.DiscountMap;
import fruit.FruitFactory;
import fruit.FruitMap;
import impl.Fruit;

public class main {

    public static void main(String[] args) {
        FruitMap.initFruitList();
        DiscountMap.initDiscountEnum();
        FruitFactory fruitFactory = new FruitFactory();
        Fruit apple = fruitFactory.getFruit("apple").setPrice(1.5).setKilogram(2.0);
        Fruit strawberry = fruitFactory.getFruit("strawberry").setPrice(2.5).setKilogram(4.0);
        DisCountFactory calcuFactory = new DisCountFactory();
        calcuFactory.calculatePrice(apple, strawberry);
    }
}
